.class public Lcom/estrongs/android/ui/dialog/p;
.super Ljava/lang/Object;
.source "CloudFileSharingDialog.java"


# instance fields
.field private a:Landroid/app/Activity;

.field private b:Lcom/estrongs/android/ui/dialog/q;

.field private c:Ljava/lang/String;

.field private d:Ljava/lang/String;

.field private e:Ljava/lang/String;

.field private f:Ljava/lang/String;

.field private g:Ljava/lang/String;

.field private h:Ljava/lang/String;

.field private i:Z

.field j:Les/z60;


# direct methods
.method public constructor <init>(Landroid/app/Activity;Ljava/lang/String;Landroid/content/DialogInterface$OnDismissListener;)V
    .locals 6

    .line 1
    invoke-direct {p0}, Ljava/lang/Object;-><init>()V

    const/4 v0, 0x0

    .line 2
    iput-object v0, p0, Lcom/estrongs/android/ui/dialog/p;->e:Ljava/lang/String;

    .line 3
    iput-object v0, p0, Lcom/estrongs/android/ui/dialog/p;->f:Ljava/lang/String;

    .line 4
    iput-object v0, p0, Lcom/estrongs/android/ui/dialog/p;->g:Ljava/lang/String;

    const-string v0, "/ES\u4e91\u5206\u4eab"

    .line 5
    iput-object v0, p0, Lcom/estrongs/android/ui/dialog/p;->h:Ljava/lang/String;

    .line 6
    iput-object p1, p0, Lcom/estrongs/android/ui/dialog/p;->a:Landroid/app/Activity;

    .line 7
    iput-object p2, p0, Lcom/estrongs/android/ui/dialog/p;->c:Ljava/lang/String;

    .line 8
    new-instance p1, Landroid/content/Intent;

    const-string p2, "android.intent.action.SEND"

    invoke-direct {p1, p2}, Landroid/content/Intent;-><init>(Ljava/lang/String;)V

    const-string p2, "text/plain"

    .line 9
    invoke-virtual {p1, p2}, Landroid/content/Intent;->setType(Ljava/lang/String;)Landroid/content/Intent;

    .line 10
    iget-object p2, p0, Lcom/estrongs/android/ui/dialog/p;->a:Landroid/app/Activity;

    invoke-virtual {p2}, Landroid/app/Activity;->getPackageManager()Landroid/content/pm/PackageManager;

    move-result-object p2

    const/4 v0, 0x0

    .line 11
    invoke-virtual {p2, p1, v0}, Landroid/content/pm/PackageManager;->queryIntentActivities(Landroid/content/Intent;I)Ljava/util/List;

    move-result-object v1

    .line 12
    new-instance v2, Ljava/util/ArrayList;

    invoke-direct {v2}, Ljava/util/ArrayList;-><init>()V

    const/4 v3, 0x0

    .line 13
    :goto_0
    invoke-interface {v1}, Ljava/util/List;->size()I

    move-result v4

    if-ge v3, v4, :cond_1

    .line 14
    invoke-interface {v1, v3}, Ljava/util/List;->get(I)Ljava/lang/Object;

    move-result-object v4

    check-cast v4, Landroid/content/pm/ResolveInfo;

    iget-object v4, v4, Landroid/content/pm/ResolveInfo;->activityInfo:Landroid/content/pm/ActivityInfo;

    iget-object v4, v4, Landroid/content/pm/ActivityInfo;->applicationInfo:Landroid/content/pm/ApplicationInfo;

    iget-object v4, v4, Landroid/content/pm/ApplicationInfo;->packageName:Ljava/lang/String;

    if-eqz v4, :cond_0

    .line 15
    iget-object v5, p0, Lcom/estrongs/android/ui/dialog/p;->a:Landroid/app/Activity;

    invoke-virtual {v5}, Landroid/app/Activity;->getPackageName()Ljava/lang/String;

    move-result-object v5

    invoke-virtual {v4, v5}, Ljava/lang/String;->equals(Ljava/lang/Object;)Z

    move-result v4

    if-eqz v4, :cond_0

    .line 16
    invoke-interface {v1, v3}, Ljava/util/List;->get(I)Ljava/lang/Object;

    move-result-object v4

    invoke-interface {v2, v4}, Ljava/util/List;->add(Ljava/lang/Object;)Z

    :cond_0
    add-int/lit8 v3, v3, 0x1

    goto :goto_0

    .line 17
    :cond_1
    invoke-interface {v2}, Ljava/util/List;->iterator()Ljava/util/Iterator;

    move-result-object v2

    :goto_1
    invoke-interface {v2}, Ljava/util/Iterator;->hasNext()Z

    move-result v3

    if-eqz v3, :cond_2

    invoke-interface {v2}, Ljava/util/Iterator;->next()Ljava/lang/Object;

    move-result-object v3

    check-cast v3, Landroid/content/pm/ResolveInfo;

    .line 18
    invoke-interface {v1, v3}, Ljava/util/List;->remove(Ljava/lang/Object;)Z

    goto :goto_1

    .line 19
    :cond_2
    invoke-interface {v1}, Ljava/util/List;->size()I

    move-result v2

    new-array v2, v2, [Landroid/graphics/drawable/Drawable;

    .line 20
    invoke-interface {v1}, Ljava/util/List;->size()I

    move-result v3

    new-array v3, v3, [Ljava/lang/String;

    const/4 v4, 0x0

    .line 21
    :goto_2
    invoke-interface {v1}, Ljava/util/List;->size()I

    move-result v5

    if-ge v4, v5, :cond_3

    .line 22
    invoke-interface {v1, v4}, Ljava/util/List;->get(I)Ljava/lang/Object;

    move-result-object v5

    check-cast v5, Landroid/content/pm/ResolveInfo;

    invoke-virtual {v5, p2}, Landroid/content/pm/ResolveInfo;->loadIcon(Landroid/content/pm/PackageManager;)Landroid/graphics/drawable/Drawable;

    move-result-object v5

    aput-object v5, v2, v4

    .line 23
    invoke-interface {v1, v4}, Ljava/util/List;->get(I)Ljava/lang/Object;

    move-result-object v5

    check-cast v5, Landroid/content/pm/ResolveInfo;

    invoke-virtual {v5, p2}, Landroid/content/pm/ResolveInfo;->loadLabel(Landroid/content/pm/PackageManager;)Ljava/lang/CharSequence;

    move-result-object v5

    aput-object v5, v3, v4

    add-int/lit8 v4, v4, 0x1

    goto :goto_2

    .line 24
    :cond_3
    new-instance p2, Lcom/estrongs/android/ui/dialog/q$n;

    iget-object v4, p0, Lcom/estrongs/android/ui/dialog/p;->a:Landroid/app/Activity;

    invoke-direct {p2, v4}, Lcom/estrongs/android/ui/dialog/q$n;-><init>(Landroid/content/Context;)V

    const v4, 0x7f11027b

    invoke-virtual {p2, v4}, Lcom/estrongs/android/ui/dialog/q$n;->b(I)Lcom/estrongs/android/ui/dialog/q$n;

    new-instance v4, Lcom/estrongs/android/ui/dialog/p$b;

    invoke-direct {v4, p0, v1, p1}, Lcom/estrongs/android/ui/dialog/p$b;-><init>(Lcom/estrongs/android/ui/dialog/p;Ljava/util/List;Landroid/content/Intent;)V

    .line 25
    invoke-virtual {p2, v2, v3, v0, v4}, Lcom/estrongs/android/ui/dialog/q$n;->a([Landroid/graphics/drawable/Drawable;[Ljava/lang/CharSequence;ILandroid/content/DialogInterface$OnClickListener;)Lcom/estrongs/android/ui/dialog/q$n;

    .line 26
    invoke-virtual {p2, v0}, Lcom/estrongs/android/ui/dialog/q$n;->d(Z)Lcom/estrongs/android/ui/dialog/q$n;

    new-instance p1, Lcom/estrongs/android/ui/dialog/p$a;

    invoke-direct {p1, p0, p3}, Lcom/estrongs/android/ui/dialog/p$a;-><init>(Lcom/estrongs/android/ui/dialog/p;Landroid/content/DialogInterface$OnDismissListener;)V

    invoke-virtual {p2, p1}, Lcom/estrongs/android/ui/dialog/q$n;->a(Landroid/content/DialogInterface$OnDismissListener;)Lcom/estrongs/android/ui/dialog/q$n;

    .line 27
    invoke-virtual {p2, v0}, Lcom/estrongs/android/ui/dialog/q$n;->c(Z)Lcom/estrongs/android/ui/dialog/q$n;

    invoke-virtual {p2}, Lcom/estrongs/android/ui/dialog/q$n;->a()Lcom/estrongs/android/ui/dialog/q;

    move-result-object p1

    iput-object p1, p0, Lcom/estrongs/android/ui/dialog/p;->b:Lcom/estrongs/android/ui/dialog/q;

    return-void
.end method

.method private a(JJ)D
    .locals 3

    const-wide/16 v0, 0x0

    cmp-long v2, p3, v0

    if-nez v2, :cond_0

    const-wide/high16 p1, 0x3ff0000000000000L    # 1.0

    return-wide p1

    :cond_0
    long-to-float p1, p1

    long-to-float p2, p3

    div-float/2addr p1, p2

    const/high16 p2, 0x42c80000    # 100.0f

    mul-float p1, p1, p2

    .line 26
    new-instance p2, Ljava/math/BigDecimal;

    float-to-double p3, p1

    invoke-direct {p2, p3, p4}, Ljava/math/BigDecimal;-><init>(D)V

    const/4 p1, 0x2

    const/4 p3, 0x4

    .line 27
    invoke-virtual {p2, p1, p3}, Ljava/math/BigDecimal;->setScale(II)Ljava/math/BigDecimal;

    move-result-object p1

    invoke-virtual {p1}, Ljava/math/BigDecimal;->doubleValue()D

    move-result-wide p1

    return-wide p1
.end method

.method static synthetic a(Lcom/estrongs/android/ui/dialog/p;JJ)D
    .locals 0

    .line 3
    invoke-direct {p0, p1, p2, p3, p4}, Lcom/estrongs/android/ui/dialog/p;->a(JJ)D

    move-result-wide p0

    return-wide p0
.end method

.method static synthetic a(Lcom/estrongs/android/ui/dialog/p;Ljava/lang/String;)Ljava/lang/String;
    .locals 0

    .line 4
    iput-object p1, p0, Lcom/estrongs/android/ui/dialog/p;->d:Ljava/lang/String;

    return-object p1
.end method

.method static synthetic a(Lcom/estrongs/android/ui/dialog/p;Ljava/lang/String;Z)V
    .locals 0

    .line 5
    invoke-direct {p0, p1, p2}, Lcom/estrongs/android/ui/dialog/p;->a(Ljava/lang/String;Z)V

    return-void
.end method

.method private a(Ljava/lang/String;)V
    .locals 2

    .line 7
    new-instance v0, Ljava/lang/Thread;

    new-instance v1, Lcom/estrongs/android/ui/dialog/p$d;

    invoke-direct {v1, p0, p1}, Lcom/estrongs/android/ui/dialog/p$d;-><init>(Lcom/estrongs/android/ui/dialog/p;Ljava/lang/String;)V

    invoke-direct {v0, v1}, Ljava/lang/Thread;-><init>(Ljava/lang/Runnable;)V

    .line 8
    invoke-virtual {v0}, Ljava/lang/Thread;->start()V

    return-void
.end method

.method private a(Ljava/lang/String;Z)V
    .locals 2

    .line 6
    iget-object v0, p0, Lcom/estrongs/android/ui/dialog/p;->a:Landroid/app/Activity;

    new-instance v1, Lcom/estrongs/android/ui/dialog/p$c;

    invoke-direct {v1, p0, p1, p2}, Lcom/estrongs/android/ui/dialog/p$c;-><init>(Lcom/estrongs/android/ui/dialog/p;Ljava/lang/String;Z)V

    invoke-virtual {v0, v1}, Landroid/app/Activity;->runOnUiThread(Ljava/lang/Runnable;)V

    return-void
.end method

.method static synthetic a(Lcom/estrongs/android/ui/dialog/p;)Z
    .locals 0

    .line 1
    iget-boolean p0, p0, Lcom/estrongs/android/ui/dialog/p;->i:Z

    return p0
.end method

.method static synthetic a(Lcom/estrongs/android/ui/dialog/p;Z)Z
    .locals 0

    .line 2
    iput-boolean p1, p0, Lcom/estrongs/android/ui/dialog/p;->i:Z

    return p1
.end method

.method static synthetic b(Lcom/estrongs/android/ui/dialog/p;)Ljava/lang/String;
    .locals 0

    .line 1
    iget-object p0, p0, Lcom/estrongs/android/ui/dialog/p;->d:Ljava/lang/String;

    return-object p0
.end method

.method static synthetic b(Lcom/estrongs/android/ui/dialog/p;Ljava/lang/String;)Ljava/lang/String;
    .locals 0

    .line 2
    iput-object p1, p0, Lcom/estrongs/android/ui/dialog/p;->g:Ljava/lang/String;

    return-object p1
.end method

.method static synthetic c(Lcom/estrongs/android/ui/dialog/p;)Ljava/lang/String;
    .locals 0

    .line 1
    iget-object p0, p0, Lcom/estrongs/android/ui/dialog/p;->g:Ljava/lang/String;

    return-object p0
.end method

.method static synthetic c(Lcom/estrongs/android/ui/dialog/p;Ljava/lang/String;)Ljava/lang/String;
    .locals 0

    .line 2
    iput-object p1, p0, Lcom/estrongs/android/ui/dialog/p;->f:Ljava/lang/String;

    return-object p1
.end method

.method static synthetic d(Lcom/estrongs/android/ui/dialog/p;)Ljava/lang/String;
    .locals 0

    .line 1
    iget-object p0, p0, Lcom/estrongs/android/ui/dialog/p;->f:Ljava/lang/String;

    return-object p0
.end method

.method static synthetic d(Lcom/estrongs/android/ui/dialog/p;Ljava/lang/String;)Ljava/lang/String;
    .locals 0

    .line 2
    iput-object p1, p0, Lcom/estrongs/android/ui/dialog/p;->e:Ljava/lang/String;

    return-object p1
.end method

.method static synthetic e(Lcom/estrongs/android/ui/dialog/p;)Landroid/app/Activity;
    .locals 0

    .line 1
    iget-object p0, p0, Lcom/estrongs/android/ui/dialog/p;->a:Landroid/app/Activity;

    return-object p0
.end method

.method static synthetic e(Lcom/estrongs/android/ui/dialog/p;Ljava/lang/String;)V
    .locals 0

    .line 2
    invoke-direct {p0, p1}, Lcom/estrongs/android/ui/dialog/p;->a(Ljava/lang/String;)V

    return-void
.end method

.method static synthetic f(Lcom/estrongs/android/ui/dialog/p;)Ljava/lang/String;
    .locals 0

    .line 1
    iget-object p0, p0, Lcom/estrongs/android/ui/dialog/p;->e:Ljava/lang/String;

    return-object p0
.end method

.method static synthetic g(Lcom/estrongs/android/ui/dialog/p;)Lcom/estrongs/android/ui/dialog/q;
    .locals 0

    .line 1
    iget-object p0, p0, Lcom/estrongs/android/ui/dialog/p;->b:Lcom/estrongs/android/ui/dialog/q;

    return-object p0
.end method

.method static synthetic h(Lcom/estrongs/android/ui/dialog/p;)Ljava/lang/String;
    .locals 0

    .line 1
    iget-object p0, p0, Lcom/estrongs/android/ui/dialog/p;->c:Ljava/lang/String;

    return-object p0
.end method


# virtual methods
.method public a()V
    .locals 7

    .line 9
    :try_start_0
    iget-object v0, p0, Lcom/estrongs/android/ui/dialog/p;->b:Lcom/estrongs/android/ui/dialog/q;

    invoke-virtual {v0}, Lcom/estrongs/android/ui/dialog/q;->show()V
    :try_end_0
    .catch Ljava/lang/Exception; {:try_start_0 .. :try_end_0} :catch_0

    goto :goto_0

    :catch_0
    move-exception v0

    .line 10
    invoke-virtual {v0}, Ljava/lang/Exception;->printStackTrace()V

    .line 11
    :goto_0
    iget-object v0, p0, Lcom/estrongs/android/ui/dialog/p;->c:Ljava/lang/String;

    invoke-static {v0}, Les/j30;->p(Ljava/lang/String;)Z

    move-result v0

    if-eqz v0, :cond_0

    .line 12
    iget-object v0, p0, Lcom/estrongs/android/ui/dialog/p;->c:Ljava/lang/String;

    invoke-direct {p0, v0}, Lcom/estrongs/android/ui/dialog/p;->a(Ljava/lang/String;)V

    goto/16 :goto_1

    .line 13
    :cond_0
    iget-object v0, p0, Lcom/estrongs/android/ui/dialog/p;->c:Ljava/lang/String;

    invoke-static {v0}, Lcom/estrongs/android/util/h0;->y1(Ljava/lang/String;)Z

    move-result v0

    if-eqz v0, :cond_1

    .line 14
    new-instance v0, Ljava/lang/StringBuilder;

    invoke-direct {v0}, Ljava/lang/StringBuilder;-><init>()V

    invoke-static {}, Lcom/estrongs/android/ui/pcs/f;->k()Lcom/estrongs/android/ui/pcs/f;

    move-result-object v1

    invoke-virtual {v1}, Lcom/estrongs/android/ui/pcs/f;->f()Ljava/lang/String;

    move-result-object v1

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    const-string v1, "/files"

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    iget-object v1, p0, Lcom/estrongs/android/ui/dialog/p;->h:Ljava/lang/String;

    invoke-virtual {v0, v1}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {v0}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object v0

    .line 15
    new-instance v1, Les/z60;

    iget-object v2, p0, Lcom/estrongs/android/ui/dialog/p;->a:Landroid/app/Activity;

    invoke-static {v2}, Lcom/estrongs/fs/f;->a(Landroid/content/Context;)Lcom/estrongs/fs/f;

    move-result-object v2

    iget-object v3, p0, Lcom/estrongs/android/ui/dialog/p;->a:Landroid/app/Activity;

    invoke-static {v3}, Lcom/estrongs/fs/f;->a(Landroid/content/Context;)Lcom/estrongs/fs/f;

    move-result-object v3

    iget-object v4, p0, Lcom/estrongs/android/ui/dialog/p;->c:Ljava/lang/String;

    .line 16
    invoke-virtual {v3, v4}, Lcom/estrongs/fs/f;->g(Ljava/lang/String;)Lcom/estrongs/fs/g;

    move-result-object v3

    invoke-static {v0}, Lcom/estrongs/fs/f;->r(Ljava/lang/String;)Lcom/estrongs/fs/g;

    move-result-object v4

    invoke-direct {v1, v2, v3, v4}, Les/z60;-><init>(Lcom/estrongs/fs/f;Lcom/estrongs/fs/g;Lcom/estrongs/fs/g;)V

    iput-object v1, p0, Lcom/estrongs/android/ui/dialog/p;->j:Les/z60;

    const/4 v2, 0x0

    .line 17
    invoke-virtual {v1, v2}, Les/z60;->i(Z)V

    .line 18
    iget-object v1, p0, Lcom/estrongs/android/ui/dialog/p;->j:Les/z60;

    iget-object v3, p0, Lcom/estrongs/android/ui/dialog/p;->a:Landroid/app/Activity;

    const v4, 0x7f1102b0

    invoke-virtual {v3, v4}, Landroid/app/Activity;->getString(I)Ljava/lang/String;

    move-result-object v3

    const/4 v4, 0x1

    new-array v5, v4, [Ljava/lang/Object;

    .line 19
    invoke-static {v0}, Lcom/estrongs/android/util/h0;->m(Ljava/lang/String;)Ljava/lang/String;

    move-result-object v6

    aput-object v6, v5, v2

    .line 20
    invoke-static {v3, v5}, Ljava/lang/String;->format(Ljava/lang/String;[Ljava/lang/Object;)Ljava/lang/String;

    move-result-object v2

    invoke-virtual {v1, v2}, Les/s80;->a(Ljava/lang/String;)V

    .line 21
    iget-object v1, p0, Lcom/estrongs/android/ui/dialog/p;->j:Les/z60;

    invoke-virtual {v1, v4}, Les/z60;->e(Z)V

    .line 22
    iget-object v1, p0, Lcom/estrongs/android/ui/dialog/p;->j:Les/z60;

    new-instance v2, Lcom/estrongs/android/ui/dialog/p$e;

    invoke-direct {v2, p0, v0}, Lcom/estrongs/android/ui/dialog/p$e;-><init>(Lcom/estrongs/android/ui/dialog/p;Ljava/lang/String;)V

    invoke-virtual {v1, v2}, Les/s80;->a(Les/z80;)V

    .line 23
    new-instance v0, Lcom/estrongs/android/ui/dialog/p$f;

    invoke-direct {v0, p0}, Lcom/estrongs/android/ui/dialog/p$f;-><init>(Lcom/estrongs/android/ui/dialog/p;)V

    .line 24
    iget-object v1, p0, Lcom/estrongs/android/ui/dialog/p;->j:Les/z60;

    invoke-virtual {v1, v0}, Les/z60;->a(Les/w80;)V

    .line 25
    iget-object v0, p0, Lcom/estrongs/android/ui/dialog/p;->j:Les/z60;

    invoke-virtual {v0}, Les/s80;->d()V

    :cond_1
    :goto_1
    return-void
.end method
